def sumFor(start, end):
    sum = 0
    for n in range(start, end + 1, 1):
        sum = sum + n
    return sum

def sumWhile(start, end):
    sum = 0
    for n in range(start, end + 1, 1):
        sum = sum + n
    return sum

print("计科2011-12-匡鑫")
print(sumFor(1, 100))
print(sumWhile(1, 100))